YNQ  YNQ-1.5.2
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups

Modules

 Direct Transfer
 

Macros

#define SY_LOCALHOSTIP4   /*{0, 0} */ {0x7f00 , 0x0001}
 
#define SY_LOCALHOSTIP6   {0, 0, 0, 0, 0, 0, 0, 1} /* {0, 0, 0, 0, 0, 0, 0, 0} */
 
#define SY_LINKLOCALIP   0xfe80
 
#define SY_ANYIP4   {0, 0}
 
#define SY_ANYIP6   {0, 0, 0, 0, 0, 0, 0, 0}
 
#define SY_ZEROIP   {0, 0, 0, 0, 0, 0, 0, 0}
 
#define SY_ZEROIP4   0L
 
#define syGetHostName(_name, _nameLen)   gethostname((_name), (_nameLen))
 

Functions

NQ_UINT32 syGetIPv6ScopeId (const NQ_IPADDRESS6 ip)
 
NQ_IPADDRESS4 syGetHostByName (const char *name)
 
void syGetDnsParams (NQ_CHAR *domain, NQ_IPADDRESS *server)
 
void syGetMacAddress (NQ_IPADDRESS4 ip, NQ_BYTE *macBuffer)
 
NQ_STATUS syGetAdapter (NQ_INDEX adapterIdx, NQ_INDEX *osIndex, NQ_IPADDRESS4 *pIp, NQ_IPADDRESS6 *ip6, NQ_IPADDRESS4 *pSubnet, NQ_IPADDRESS4 *pBcast, NQ_WCHAR *pWins, NQ_WCHAR *pDns)
 

Detailed Description

Macro Definition Documentation

#define SY_LOCALHOSTIP4   /*{0, 0} */ {0x7f00 , 0x0001}
#define SY_LOCALHOSTIP6   {0, 0, 0, 0, 0, 0, 0, 1} /* {0, 0, 0, 0, 0, 0, 0, 0} */
#define SY_LINKLOCALIP   0xfe80
#define SY_ANYIP4   {0, 0}
#define SY_ANYIP6   {0, 0, 0, 0, 0, 0, 0, 0}
#define SY_ZEROIP   {0, 0, 0, 0, 0, 0, 0, 0}
#define SY_ZEROIP4   0L
#define syGetHostName (   _name,
  _nameLen 
)    gethostname((_name), (_nameLen))

Function Documentation

NQ_UINT32 syGetIPv6ScopeId ( const NQ_IPADDRESS6  ip)

Get IPv6 scope ID

Parameters
ipThe IPv6 address
Returns
0..n - The scope id to be used
Note
0 - Unknown network interface
NQ_IPADDRESS4 syGetHostByName ( const char *  name)

Find host IP by its name

Parameters
nameHost name
Returns
Host IP
void syGetDnsParams ( NQ_CHAR domain,
NQ_IPADDRESS server 
)

Returns the DNS initializations parameters

Parameters
domainThe default domain target belongs to
serverThe DNS server IP address
void syGetMacAddress ( NQ_IPADDRESS4  ip,
NQ_BYTE macBuffer 
)

Get MAC address by IP4

Parameters
ipNext IP address
macBufferBuffer for mac address
NQ_STATUS syGetAdapter ( NQ_INDEX  adapterIdx,
NQ_INDEX osIndex,
NQ_IPADDRESS4 pIp,
NQ_IPADDRESS6 ip6,
NQ_IPADDRESS4 pSubnet,
NQ_IPADDRESS4 pBcast,
NQ_WCHAR pWins,
NQ_WCHAR pDns 
)

Get adapter information

Parameters
adapterIdxAdapter number (zero based)
osIndexBuffer for adapter index as defined by the OS
pIpBuffer for adapter IP in NBO
ip6Buffer for adapter IPv6 in NBO
pSubnetBuffer for subnet address in NBO
pBcastBuffer for bcast address in NBO
pWinsBuffer for semicolon delimited list of WINS servers
pDnsBuffer for semicolon delimited list of DNS servers
Returns
NQ_FAIL when there is no adapter with the given index, NQ_SUCCESS when adapter information available